<?php

namespace App\Http\Requests\User\Personal;

use Illuminate\Foundation\Http\FormRequest;

class ReportStation extends FormRequest
{
    /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
        	'station_id' => 'required',
        	'timing_id' => 'required',
			'longitude' => 'required',
			'latitude' => 'required',
			'address' => 'required',
			'example' => 'required',
			'image' => 'required'
        ];
    }

	/**
	 * Date: 30/04/2018
	 * @author George
	 * @return array
	 */
	public function messages()
	{
		return [
			'station_id.required' => '请选择岗点',
			'timing_id.required' => '请选择时间点',
			'longitude.required' => '无法获取你的经度信息',
			'latitude.required' => '无法获取您的纬度信息',
			'address.required' => '无法获取地址信息',
			'example' => '无法获取示例图片',
			'image' => '请上传岗点拍摄图片',
		];
    }
}
